//---------------------------------------------------------------------------

#ifndef TCreateIntegFormH
#define TCreateIntegFormH
//---------------------------------------------------------------------------
#include <vcl.h>
#include <Classes.hpp>
#include <Controls.hpp>
#include <StdCtrls.hpp>
#include <Forms.hpp>
#include <ExtCtrls.hpp>
#include <Buttons.hpp>
#include <Dialogs.hpp>
#include <ExtDlgs.hpp>
#include "TArea.h"
#include "TGRA.h"
#include "CSPIN.h"
#include "TFrame1.h"
#include "TUnitsGroup.h"
#include <ActnList.hpp>
#include <ActnMan.hpp>
//---------------------------------------------------------------------------
class TCreateIntegForm : public TForm
{
__published:	// IDE-managed Components
        TGroupBox *AprasasGB;
        TButton *CreateBtn;
        TButton *CancelBtn;
        TMemo *ShortDescMemo;
        TLabel *Label4;
        TEdit *HelpFNEdit;
        TLabel *Label6;
        TSpeedButton *OpenHelpBtn;
        TOpenDialog *OpenDialog;
        TGroupBox *ParamsGB;
        TPanel *Panel;
        TPanel *Panel1;
        TLabel *Parametrai;
        TBevel *Bevel3;
        TLabel *Label2;
        TLabel *Label7;
        TLabel *Label8;
        TCSpinEdit *CountCSpin;
        TLabel *Label9;
        TLabel *Label10;
        TLabel *Label12;
        TFrame1 *Frame1;
        TMemo *SavingMemo;
        TButton *HelpBtn;
        TLabel *Label11;
        TGroupBox *ParinktysGB;
        TLabel *Label1;
        TEdit *NameEdit;
        TComboBox *AreaComboB;
        TButton *AreaBtn;
        TButton *GraphBtn;
        TLabel *Label3;
        TMemo *FormulaMemo;
        TLabel *ProjLabel;
        TSpeedButton *WorPadBtn;
        TActionManager *AM;
        TAction *UnitsBtnClick;
        void __fastcall CreateBtnClick(TObject *Sender);
        void __fastcall CancelBtnClick(TObject *Sender);
        void __fastcall FormShow(TObject *Sender);
        void __fastcall AreaBtnClick(TObject *Sender);
        void __fastcall GraphBtnClick(TObject *Sender);
        void __fastcall CountCSpinChange(TObject *Sender);
        void __fastcall FormClose(TObject *Sender, TCloseAction &Action);
        void __fastcall OpenHelpBtnClick(TObject *Sender);
        void __fastcall FormulaMemoKeyDown(TObject *Sender, WORD &Key,
          TShiftState Shift);
        void __fastcall WorPadBtnClick(TObject *Sender);
        void __fastcall HelpBtnClick(TObject *Sender);
        void __fastcall UnitsBtnClickExecute(TObject *Sender);
private:	// User declarations
  AnsiString OldFN;
  int ParamsCountA;
  int ParamsCountB;
  int Focused;
  int Top;
  TArea *Area;
  TGRA *GRA;
  TUnitsGroup *UnitsG[20];
  TEdit *LabelEdit[20];
  TEdit *MarkEdit[20];
  TEdit *ValueEdit[20];
  TButton *UnitsBtn[20];
  void __fastcall CreateFields();
  void __fastcall Define();
        int __fastcall GetFocusedBtn();
public:		// User declarations
  bool New;  // true - new, false - edit
  __fastcall TCreateIntegForm(TComponent* Owner);
  void __fastcall SetCurTopic(AnsiString Name);
        bool __fastcall CheckForErrors();
};
//---------------------------------------------------------------------------
extern PACKAGE TCreateIntegForm *CreateIntegForm;
//---------------------------------------------------------------------------
#endif
